import request from '@/config/axios'

// 记账企业调价记录 VO
export interface PriceAdjustmentVO {
  id: number // 序号
  accountingCompaniesId: number // 记账企业ID
  adjustYear: number // 调价年份
  adjustMonth: number // 调价月份
  price: number // 收费价格(元)
  remarks: string // 备注
  creatorName: string // 创建者
  createTime: Date // 创建时间
  updaterName: string // 更新者
  updateTime: Date // 更新时间
}

// 记账企业调价记录 API
export const PriceAdjustmentApi = {
  // 查询记账企业调价记录列表
  getPriceAdjustmentList: async (accountingCompaniesId: number) => {
    return await request.get({ url: `/oa/accounting-companies/price-adjustment/list?accountingCompaniesId=${accountingCompaniesId}` })
  },

  // 查询记账企业调价记录详情
  getPriceAdjustment: async (id: number) => {
    return await request.get({ url: `/oa/accounting-companies/price-adjustment/get?id=${id}` })
  },

  // 新增记账企业调价记录
  createPriceAdjustment: async (data: PriceAdjustmentVO) => {
    return await request.post({ url: `/oa/accounting-companies/price-adjustment/create`, data })
  },

  // 修改记账企业调价记录
  updatePriceAdjustment: async (data: PriceAdjustmentVO) => {
    return await request.put({ url: `/oa/accounting-companies/price-adjustment/update`, data })
  },

  // 删除记账企业调价记录
  deletePriceAdjustment: async (id: number) => {
    return await request.delete({ url: `/oa/accounting-companies/price-adjustment/delete?id=${id}` })
  }
} 